package pers.jg.rrsserver.entity

import jakarta.persistence.Column
import jakarta.persistence.Entity
import jakarta.persistence.Id
import jakarta.persistence.Table
import java.sql.Timestamp

@Entity
@Table(name = "goods")
open class Goods {
    @Id
    @Column(name = "id", nullable = false, length = 45)
    open var id: String? = null

    @Column(name = "name", nullable = false, length = 45)
    open var name: String? = null

    @Column(name = "price_cent")
    open var priceCent: Int? = null

    @Column(name = "img", length = 45)
    open var img: String? = null

    @Column(name = "introduction", length = 1024)
    open var introduction: String? = null

    @Column(name = "seller_id", length = 45)
    open var sellerId: Int? = null

    @Column(name = "inventory")
    open var inventory: Int? = null

    @Column(name = "add_time")
    open var addTime: Timestamp? = null

    @Column(name = "sales")
    open var sales: Int? = null

    @Column(name = "type", length = 45)
    open var type: String? = null
}